%%
%% This is file `sjtuthesis-undergraduate.ltx',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% sjtuthesis.dtx  (with options: `undergraduate')
%% 
%% Copyright (C) 2009-2017 by weijianwen <weijianwen@gmail.com>
%%           (C) 2018-2021 by SJTUG
%% 
%% This file may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3c
%% of this license or (at your option) any later version.
%% The latest version of this license is in
%%     https://www.latex-project.org/lppl.txt
%% and version 1.3c or later is part of all distributions of LaTeX
%% version 2005/12/01 or later.
%% 
%% This file has the LPPL maintenance status "maintained".
%% 
%% The Current Maintainer of this work is Alexara Wu.
%% 
\ProvidesFile{sjtuthesis-undergraduate.ltx}
  [2021/06/03 1.1.0rc1 Shanghai Jiao Tong University Thesis Template]
\geometry{%
  paper      = a4paper,
  top        = 84bp,
  bottom     = 72bp,
  left       = 90bp,
  right      = 90bp,
  headheight = 60bp,
  headsep    = 8bp,
}
\pagestyle{fancy}
\ifsjtu@language@chinese
  \newcommand\sjtu@thepage@format[2]{第~{#1}~页\,共~{#2}~页}
\else
  \newcommand\sjtu@thepage@format[2]{--~~Page~~{#1}~~of~~{#2}~~--}
\fi
\fancypagestyle{plain}{%
  \fancyhf{}
  \fancyhead[L]{%
    \includegraphics[height=32pt]%
      {sjtu-vi-logo-\sjtu@style@header@logo@color.pdf}
  }
  \fancyhead[R]{%
    \parbox[b]{0.7\textwidth}{%
      \raggedleft\zihao{-5}\heiti\MakeUppercase{\sjtu@info@running@title}
    }
  }
  \fancyfoot[C]{%
    \ifsjtu@page@numbering
      \zihao{-5}\sjtu@thepage@format{\sjtu@thepage}{\sjtu@lastpageref}%
    \fi
  }
  \renewcommand\headrulewidth{0.75pt}
}
\ctexset{%
  subsection/format = \zihao{-4}\normalfont,
}
\renewcommand\cftchapfont{\normalfont}
\ifsjtu@type@bachelor
  \sjtusetup{
    style = {
      frontmatter-numbering = false,
      indent-headings = fixed,
    },
  }
\fi
\NewDocumentEnvironment{abstract}{}{%
  \sjtu@chapter*[\sjtu@name@abstract@zh]{%
    \sjtu@info@title@zh \vskip 2ex
    \begingroup
      \zihao{4}
      \sjtu@name@abstract@zh
    \endgroup
  }[\sjtu@name@abstract]%
}{%
  \vskip \baselineskip \noindent
  \begingroup
    \zihao{-4}
    \heiti\sjtu@name@keywords@zh
  \endgroup
  \begingroup
    \zihao{5}
    \sjtu@clist@use{\sjtu@info@keywords@zh}{，}
  \endgroup
}
\NewDocumentEnvironment{abstract*}{}{%
  \sjtu@chapter*[\sjtu@name@abstract@en]{%
    \MakeUppercase\sjtu@info@title@en \vskip 2ex
    \begingroup
      \zihao{4}
      \MakeUppercase\sjtu@name@abstract@en
    \endgroup
  }[]
}{%
  \vskip 3ex \noindent
  \begingroup
    \zihao{-4}\bfseries
    \sjtu@name@keywords@en
  \endgroup
  \begingroup
    \zihao{5}
    \sjtu@clist@use{\sjtu@info@keywords@en}{, }
  \endgroup
}
\RenewDocumentCommand{\maketitle}{}{%
  \sjtu@pdfbookmark{0}{\sjtu@name@titlepage}
  \sjtu@make@titlepage@zh%
}
\newcommand\sjtu@make@titlepage@zh{%
  \cleardoublepage
  \thispagestyle{empty}
  \begin{center}
    \kaishu
    \vspace*{48pt}
    \begingroup
      \includegraphics[height=105pt]%
        {sjtu-vi-name-\sjtu@style@title@logo@color.pdf}
      \par
    \endgroup
    {\fontsize{32}{42}\selectfont\sjtu@name@subject@zh\par}
    \vskip 6pt
    {\zihao{-2}\MakeUppercase\sjtu@name@subject@en\par}
    \vskip 16pt
    \begingroup
      \includegraphics[height=75pt]%
        {sjtu-vi-badge-\sjtu@style@title@logo@color.pdf}
      \par
    \endgroup
    \vskip \stretch{2}
    \begingroup
      \zihao{-2}
      \begin{tabular}{@{}r@{\sjtu@colon}l@{}}
        论文题目 & \sjtu@title@box[300pt]{\sjtu@info@display@title@zh}
      \end{tabular}
      \par
    \endgroup
    \vskip \stretch{1}
    \begingroup
      \zihao{3}
      \begin{tabular}{@{}F{t}{4.2\ccwd}@{\sjtu@colon}c@{}}
        \sjtu@name@author@zh      & \sjtu@info@author@zh      \\\cline{2-2}
        \sjtu@name@id@zh          & \makebox[180pt]{\sjtu@info@id} \\\cline{2-2}
        \ifsjtu@type@course
          \sjtu@name@course@zh    & \sjtu@info@course@zh      \\\cline{2-2}
        \else
          \sjtu@name@major@zh     & \sjtu@info@major@zh       \\\cline{2-2}
        \fi
        \sjtu@name@supervisor@zh  & \sjtu@info@supervisor@zh  \\\cline{2-2}
        \sjtu@name@department@zh  & \sjtu@info@department@zh  \\\cline{2-2}
      \end{tabular}
      \par
    \endgroup
    \vskip 64pt
  \end{center}
}
\endinput
%%
%% End of file `sjtuthesis-undergraduate.ltx'.
